export const instancesState = {
  Scheduled: 'Scheduled',
  Running: 'Running',
  Paused: 'Paused',
  Success: 'Success',
  Failed: 'Failed',
  Cancelled: 'Cancelled',

  // 算子
  Pending: 'Pending',
  Resume: 'Resume',
  Submitted: 'Submitted',
  Run: 'Run'
}

export const instancesStateText = {
  Scheduled: '计划',
  Running: '运行',
  Paused: '暂停',
  Success: '成功',
  Failed: '失败',
  Cancelled: '取消',

  // 算子
  Pending: '等待',
  Resume: '继续',
  Submitted: '提交'
}
export const instancesStateColor = {
  Scheduled: 'info',
  Running: '',
  Paused: 'warning',
  Success: 'success',
  Failed: 'danger',
  Cancelled: 'info',
  Pending: 'info'
}
export const operatorStatusIcon = {
  Scheduled: 'jinzhi',
  Pending: 'jinzhi',
  Success: 'chenggong',
  Failed: 'yunhangshibai',
  Running: 'shuaxin',
  Paused: 'zanting2',
  Cancelled: 'quxiao'
}

export const instancesStatusIcon = {
  Scheduled: 'el-icon-remove-outline',
  Pending: 'el-icon-remove-outline',
  Success: 'el-icon-circle-check',
  Failed: 'el-icon-circle-close',
  Running: 'el-icon-refresh-right',
  Paused: 'el-icon-video-pause',
  Cancelled: 'el-icon-discover'
}

export const questionMark = '<\?>'

export const workflowSaveStateCode = {
  loading: 'loading',
  success: 'success',
  error: 'error'
}

export const operatorIconConfig = {
  '数据读取': {
    'icon': 'wenjianduqu',
    'fill': '#EF5C5C'
  },
  '数据预处理': {
    'icon': 'yuchuli',
    'fill': '#4966E9'
  },
  '数据可视化': {
    'icon': '_keshihua',
    'fill': '#0785F9'
  },
  '统计分析': {
    'icon': 'tongjifenxi',
    'fill': '#318884'
  },
  '特征工程': {
    'icon': 'tezhenggongcheng',
    'fill': '#893636'
  },
  '机器学习': {
    'icon': 'jiqixuexi',
    'fill': '#0FBCC7'
  },
  '模型评估': {
    'icon': 'peixunpinggu',
    'fill': '#893636'
  },
  '平台功能': {
    'icon': 'pingtaigongneng',
    'fill': '#383838'
  },
  '模型训练': {
    'icon': 'moxingxunlian',
    'fill': '#893636'
  },
  '模型预测': {
    'icon': 'moxingxunlian',
    'fill': '#893636'
  }
}

export const project_role = ['项目所有者', '数据科学家', '数据工程师', '运维工程师', '算法工程师', '访客']
export const model_role = ['模型所有者', '运维工程师', '算法工程师', '访客']

export const FlowExperimentStateColorHexadecimal = {
  Scheduled: '#909399',
  Running: '#1890ff',
  Paused: '#E6A23C',
  Success: '#52c41a',
  Failed: '#ff4d4f',
  Cancelled: '#606266'
}
